﻿using System;
using System.ComponentModel.Composition;
using ModularAndPlugin.WinApp.Contracts;
using SailHero.Soft.FrameWork.IDomainRepositories.Contracts;

namespace ModularAndPlugin.WinApp.Composition
{
    public class DataModule : IDataModule, IDisposable
    {
        /// <summary>
        /// 数据操作接口
        /// </summary>
        [Import]
        public IBaseDayDataRepository baseDayDataRepository { get;set; }
        /// <summary>
        /// 数据操作接口
        /// </summary>
        [Import]
        public ITB_CLIENTSRepository tB_CLIENTSRepository { get; set; }

        /// <summary>
        /// 数据操作接口
        /// </summary>
        [Import]
        public IBaseDayDataRepository baseDayDataRepository0 { get; set; }

        public void Dispose()
        {
            if (baseDayDataRepository == null)
            {
                //DbContextManager.CloseAllDbContexts();
            }

        }
    }
}
